#!/usr/bin/env python
#coding=utf-8 
# 随机序列迭代

from random import choice

class RandSeq(object):
	def __init__(self, seq):
		self.data = seq
	def __iter__(self):
		return self
	def next(self):
		return choice(self.data)

r = RandSeq([e for e in range(15)])
print r.next() # 
print r.next()
print [e for e in range(15)]

